package everyday;

/**
 * @Author: Siantar
 * @Date: 2023-06-30-21:36
 * @Description: 1.0
 */
public class T2490 {
    public boolean isCircularSentence(String sentence) {
        String[] s = sentence.split(" ");
        char c = s[s.length - 1].charAt(s[s.length - 1].length() - 1);
        for (String e : s) {
            if (e.charAt(0) == c) {
                c = e.charAt(e.length() - 1);
            } else {
                return false;
            }
        }
        return true;
    }
}
